﻿<%@ Page Language="C#" AutoEventWireup="false" CodeFile="recCorporateActionform.aspx.cs"
    Inherits="SIPO.Web.Forms.Transaction.recCorporateActionform" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="head1" runat="server">
    <title>Form Aksi Korporasi</title>

    <link href="<%= ResolveUrl("~/styles/chosen/chosen.min.css") %>" rel="stylesheet" type="text/css" />

    <script src="<%= ResolveUrl("~/scripts/helper.js") %>" type="text/javascript"></script>
    <script src="<%= ResolveUrl("~/scripts/jquery.validate.min.js") %>" type="text/javascript"></script>
    <script src="<%= ResolveUrl("~/scripts/jquery.validate.wrapper.js") %>" type="text/javascript"></script>
    <script src="<%= ResolveUrl("~/scripts/jquery.inputmask.bundle.min.js") %>" type="text/javascript"></script>
    <script src="<%= ResolveUrl("~/scripts/jquery.realperson.min.js") %>" type="text/javascript"></script>

    <script src="<%= ResolveUrl("~/scripts/chosen/chosen.jquery.min.js") %>" type="text/javascript"></script>

    <script type="text/javascript">

        $(document).ready(function () {

            $('#ddlDebtor').chosen({placeholder_text_single:"-- pilih emiten aksi --"});
            $('#ddlWilayah').chosen({placeholder_text_single:"-- pilih wilayah --"});
            $('#ddlKota').chosen({placeholder_text_single:"-- pilih kota --"});
            $('#ddlSubSubSector').chosen({placeholder_text_single:"-- pilih jenis usaha emiten --"});

        });

    </script>

    <script type="text/javascript">
        //fungsi untuk membuat captcha menjadi expire dalam satuan waktu
        var timoutNow = 300000; // waktu expire 5 minute

        //var warningTimer;
        var timeoutTimer;

        // Start timers.
        function StartTimers() {
            timeoutTimer = setTimeout("IdleTimeout();", timoutNow);
        }

        // Reset timers.
        function ResetTimers() {
            clearTimeout(timeoutTimer);
            StartTimers();
        }

        function IdleTimeout() {
            $('#txtExpire').val('1');
        }

        function RefreshCaptcha() {

            $('#txtCaptcha1').realperson('destroy');
            $('#txtCaptcha1').realperson({
                regenerate: 'Klik untuk mengubah',
                length: 5,
                includeNumbers: true
            });
            $('#txtCaptcha1').val('');
            $('#txtCaptcha1').focus();
            $('#txtExpire').val('0');
            ResetTimers();

        }

    </script>
    <script type="text/javascript">

        function OpenInNewTab(url) {
            var win = window.open(url, '_blank');
            win.focus();
        }

        function Disabled() {
            $('#txtNilaiEmisi').attr('disabled', 'disabled');
            $('#txtNilaiEmisi').val('');
        }

        function Enabled() {
            $('#txtNilaiEmisi').removeAttr('disabled');
        }

        function GetTariff() {

            var corporateActionTypeID = $("#ddlCorporateActionType option:selected").val();

            var nilaiEmisi = $('#txtNilaiEmisi').val();
          
            var subSubSectorId = ($("#ddlSubSubSector option:selected").val() == undefined) ? 0 : $("#ddlSubSubSector option:selected").val().split('|')[2];

            if (corporateActionTypeID > 0 && subSubSectorId > 0) {

                var handlerUrl = '<%= ResolveUrl("~/AjaxHandler/Loaddata/getTariff.ashx?CorporateActionTypeID=' + corporateActionTypeID + '&NilaiEmisi=' + nilaiEmisi + '") %>' + '&SubSubSectorId=' + subSubSectorId;

                $.ajax({
                    type: 'POST',
                    url: handlerUrl,
                    contentType: 'application/json',
                    dataType: 'json',
                    success: function (data) {
                        if (data.IsFormula == '0' || data.IsFormula == '') {
                            $('#trNilai').hide();
                            Disabled();
                        }
                        else {
                            $('#trNilai').show();
                            Enabled();
                        }

                        $('#txtTariffId').val(data.TariffID);
                        $('#hfInvoiceValue').val(data.InvoiceValue);
                        $('#hfImpositionBaseID').val(data.ImpositionBaseID);
                    },
                    error: function () {
                        alert('Error!');
                    }
                });
            }

        }
   
    </script>
    <script type="text/javascript">

        $("#btnNext").button({ icons: { primary: "ui-icon-circle-arrow-e"} });
        $("#btnBack").button({ icons: { primary: "ui-icon-circle-arrow-w"} });
        $("#btnCancel").button({ icons: { primary: "ui-icon-close"} });
        $("#btnSubmit").button({ icons: { primary: "ui-icon-disk"} });

        $('#btnCancel').click(function () {
            parent.$('#dialog1').dialog('close');
        });       

    </script>
    <script type="text/javascript" language="javascript">

        $(document).ready(function () {

            //input captcha harus huruf besar semua
            $('#txtCaptcha1').upperCase();

            $("#tableCaptcha").hide();

            $('#txtCaptcha1').realperson({
                regenerate: 'Klik untuk mengubah',
                length: 5,
                includeNumbers: true
            });

            var isInternal = '<%= Request.Params["isInternal"] %>';

            $("#txtCorporateName").inputmask("Regex", { regex: "[A-Za-z-.0-9 ]*" });

            $("#txtCorporateSector").inputmask("Regex", { regex: "[A-Za-z-.0-9 ]*" });

            $("#txtKodePos").inputmask("Regex", { regex: "[0-9]*" });

            $("#txtTelpon").inputmask("Regex", { regex: "[0-9+-]*" });

            $("#txtFax").inputmask("Regex", { regex: "[0-9-+]*" });

            $("#txtWebsite").inputmask("Regex", { regex: "[A-Za-z-.0-9_/: ]*" });

            $("#txtAlamat1").inputmask("Regex", { regex: "[A-Za-z-.0-9 ]*" });

            $("#txtAlamat2").inputmask("Regex", { regex: "[A-Za-z-.0-9 ]*" });

            $("#txtAlamat3").inputmask("Regex", { regex: "[A-Za-z-.0-9 ]*" });

            $("#txtNPWP").inputmask('99.999.999.9-999.999');

            $('#txtNilaiEmisi').blur(function () {

                GetTariff();

            });

            $("#txtNilaiEmisi").inputmask("decimal", { radixPoint: ",", autoGroup: true, groupSeparator: ".", groupSize: 3, digits: 2, repeat: 18 });

            $.validator.addMethod("regex", function (value, element, parameters) {
                var re = new RegExp(parameters);
                return re.test(value);
            });

            // 1. prepare the validation rules and messages.
            var rules = {
                ddlDebtor: "required",
                txtCorporateName: "required",
                ddlSubSubSector: "required",
                txtNPWP: { regex: '[0-9][0-9].[0-9][0-9][0-9].[0-9][0-9][0-9].[0-9]-[0-9][0-9][0-9].[0-9][0-9][0-9]' },
                txtKodePos: "number",
                txtEmail: {
                    required: true,
                    email: true
                },
                txtWebsite: "url",
                ddlCorporateActionType: "required"
            };

            var messages = {
                ddlDebtor: "Emiten aksi wajib dipilih",
                txtCorporateName: "Nama Perusahaan wajib di isi",
                ddlSubSubSector: "Jenis usaha emiten wajib dipilih",
                txtNPWP: "Format NPWP harus benar 00.000.000.0-000.000",
                txtKodePos: "Kode pos harus di isi dengan angka",
                txtEmail: {
                    required: "Email wajib di isi",
                    email: "Format alamat Email harus berformat xxx@domain.xxx"
                },
                txtWebsite: "Alamat Website tidak valid",
                ddlCorporateActionType: "Jenis aksi korporasi wajib dipilih"
            };

            // 2. Initiate the validator
            var validator = new jQueryValidatorWrapper("form1", rules, messages);

            // 3. Set the click event to do the validation
            $("#btnNext").click(function () {

                if (!validator.validate())
                    return false;
                else {

                    var invoiceValue = $('#hfInvoiceValue').val();

                    if ($('#txtTariffId').val() == '') {
                        alert('Anda tidak bisa melanjutkan transaksi ini, karena tarif tidak tersedia!')
                        return false;
                    }

                    if (parseFloat(invoiceValue) == 0) {
                        alert('Anda tidak bisa melanjutkan transaksi ini, karena nilai setoran bernilai 0!')
                        return false;
                    }

                    $("#divKeterangan").hide();
                    $("#fsProfilPerusahaan").hide();
                    $("#fsKonfirmasi").show();
                    $("#btnNext").hide();
                    $("#btnSubmit").show();
                    $("#btnBack").show();

                    if (isInternal == 'undefined' || isInternal.toString() == "")
                        $("#tableCaptcha").show();

                    var namaAksiKorporasi = $("#ddlCorporateActionType option:selected").text();

                    var money = parseFloat(invoiceValue);

                    $.post('<%= ResolveUrl("~/AjaxHandler/LoadData/GetBeSpelled.ashx") %>' + '?invoicevalue=' + invoiceValue)
                            .done(function (data) {
                                var r = JSON.parse(data);
                                if (r.BeSpelled != '') {
                                    $("#lblValidasi").html("Biaya " + namaAksiKorporasi + " adalah sebesar Rp." + money.formatMoney(2, ".", ",") + " (" + r.BeSpelled + "). <br/> Surat setoran akan diberikan setelah proses aksi koporasi ini dikonfirmasi");
                                    $('#hdBeSpelled').val(r.BeSpelled);
                                }
                                else {
                                    $("#lblValidasi").html("Biaya " + namaAksiKorporasi + " adalah sebesar Rp." + money.formatMoney(2, ".", ",") + ". <br/> Surat setoran akan diberikan setelah proses aksi koporasi ini dikonfirmasi");
                                }
                            })
                            .fail(function () {
                                alert('Gagal mengkonversi terbilang !');
                            });
                }

                return false;

            });

            $("#btnBack").click(function () {

                $("#divKeterangan").show();
                $("#fsProfilPerusahaan").show();
                $("#fsKonfirmasi").hide();
                $("#btnSubmit").hide();
                $("#btnBack").hide();
                $("#btnNext").show();
                $("#btnClose").show();
                $("#tableCaptcha").hide();

            });

            $("#btnSubmit").click(function () {

                var id = $('#hfID').val();

                var captchaHash = $("input[name='txtCaptcha1Hash']").val();
                var captcha = $("#txtCaptcha1").val();
                var expire = $('#txtExpire').val();

                if (isInternal == "" || isInternal == 'undefined') {
                    if (id == 0) {
                        if (captcha == '') {
                            alert('Captcha harus di isi!');

                            RefreshCaptcha();

                            return false;
                        }
                    }
                }

                var corporateName = $('#txtCorporateName').val();
                var corporateSector = $('#txtCorporateSector').val();
                var npwp = $('#txtNPWP').val();
                var alamat1 = $('#txtAlamat1').val();
                var alamat2 = $('#txtAlamat2').val();
                var alamat3 = $('#txtAlamat3').val();
                var wilayahid = $("#ddlWilayah option:selected").val();
                var kotaid = $("#ddlKota option:selected").val();
                var kodePos = $('#txtKodePos').val();
                var telpon = $('#txtTelpon').val();
                var fax = $('#txtFax').val();
                var email = $('#txtEmail').val();
                var website = $('#txtWebsite').val();
                var corporateActionTypeID = $("#ddlCorporateActionType option:selected").val();


                var nilaiEmisi = $('#txtNilaiEmisi').val();

                var debtorID = $("#ddlDebtor option:selected").val();
                var tariffId = $("#txtTariffId").val();
                var invoiceValue = $("#hfInvoiceValue").val();

                var forPayment = $("#ddlCorporateActionType option:selected").text();
                var beSpelled = $("#hdBeSpelled").val();

                var impositionBaseID = $("#hfImpositionBaseID").val();

                var sectorCode = $("#ddlSubSubSector option:selected").val() == undefined ? '' : $("#ddlSubSubSector option:selected").val().split('|')[0];
                var subSectorCode = $("#ddlSubSubSector option:selected").val() == undefined ? '' : $("#ddlSubSubSector option:selected").val().split('|')[1];

                //                var debtorSectorID = $("#ddlSubSubSector option:selected").val().split('|')[3];

                var debtorSectorID = $('#hfDebtorSectorID').val();

                var objrecCorporateAction = new Object();

                objrecCorporateAction.ImpositionBaseID = encodeURIComponent(impositionBaseID);

                objrecCorporateAction.BeSpelled = encodeURIComponent(beSpelled);
                objrecCorporateAction.ForPayment = encodeURIComponent(forPayment);
                objrecCorporateAction.SectorCode = encodeURIComponent(sectorCode);
                objrecCorporateAction.SubSectorCode = encodeURIComponent(subSectorCode);

                objrecCorporateAction.CorporateActionID = encodeURIComponent(id);
                objrecCorporateAction.CorporateName = encodeURIComponent(corporateName);

                objrecCorporateAction.CorporateSector = encodeURIComponent(corporateSector);

                objrecCorporateAction.NPWP = encodeURIComponent(npwp);
                objrecCorporateAction.Address1 = encodeURIComponent(alamat1);
                objrecCorporateAction.Address2 = encodeURIComponent(alamat2);
                objrecCorporateAction.Address3 = encodeURIComponent(alamat3);
                objrecCorporateAction.RegionID = encodeURIComponent(wilayahid);
                objrecCorporateAction.CityID = encodeURIComponent(kotaid);
                objrecCorporateAction.ZipCode = encodeURIComponent(kodePos);
                objrecCorporateAction.Phone = encodeURIComponent(telpon);
                objrecCorporateAction.Fax = encodeURIComponent(fax);
                objrecCorporateAction.Email = encodeURIComponent(email);
                objrecCorporateAction.Website = encodeURIComponent(website);
                objrecCorporateAction.CorporateActionTypeID = encodeURIComponent(corporateActionTypeID);
                objrecCorporateAction.ImpositionValue = encodeURIComponent(nilaiEmisi);
                objrecCorporateAction.DebtorID = encodeURIComponent(debtorID);
                objrecCorporateAction.InvoiceValue = encodeURIComponent(invoiceValue);

                objrecCorporateAction.DebtorSectorID = encodeURIComponent(debtorSectorID);

                objrecCorporateAction.TariffID = encodeURIComponent(tariffId);
                objrecCorporateAction.BillingNo = encodeURIComponent($('#hfBillingNo').val());
                objrecCorporateAction.InvoiceNo = encodeURIComponent($('#hfInvoiceNo').val());
                objrecCorporateAction.CorporateActionDate = encodeURIComponent($('#hfCorporateActionDate').val());
                objrecCorporateAction.InvoiceDate = encodeURIComponent($('#hfInvoiceDate').val());

                if (isInternal == "" || isInternal == 'undefined') {

                    objrecCorporateAction.Captcha = encodeURIComponent(captcha);
                    objrecCorporateAction.CaptchaHash = encodeURIComponent(captchaHash);

                }
                else {

                    objrecCorporateAction.Captcha = encodeURIComponent('internal');

                }

                // variable untuk expire captcha ------------>
                objrecCorporateAction.IsExpired = encodeURIComponent(expire);

                jsonData = JSON.stringify(objrecCorporateAction);

                var handlerUrl = '<%= ResolveUrl("~/ajaxhandler/transaction/recCorporateActionhandler.ashx") %>';

                if (id == 0) {

                    $.ajax({
                        type: 'POST',
                        url: handlerUrl + "?method=insert",
                        contentType: 'application/json',
                        dataType: 'json',
                        data: jsonData,
                        success: function (data) {
                            if (data.IsSuccess) {

                                parent.$('#dialog1').dialog('close');
                                setTimeout("parent.$('#table').trigger('reloadGrid');", 3000);

                                var formUrl = '<%= ResolveUrl("~/forms/transaction/recPrintInvoiceform.aspx") %>';
                                OpenInNewTab(formUrl + '?invoiceno=' + data.Data + '&email=' + email);

                            }
                            else {
                                if (data.Message.toString().toLowerCase().indexOf('captcha') > -1) {

                                    RefreshCaptcha();

                                }
                                else {
                                    parent.$('#dialog1').dialog('close');
                                    setTimeout("parent.$('#table').trigger('reloadGrid');", 3000);
                                }

                                alert(data.Message);

                            }
                        },
                        error: function (response) {
                            var r = JSON.parse(response.responseText);
                            alert("Error Message: " + r.Message);
                        }
                    });
                }
                else {
                    CallAjax(handlerUrl, "?method=update", jsonData);
                    parent.$('#dialog1').dialog('close');
                    setTimeout("parent.$('#table').trigger('reloadGrid');", 3000);
                }

                return false;

            });

        });

       
    </script>
    <script type="text/javascript" language="javascript">

        $(function () {

            $('#trNilai').hide();

            if ('<%= base.UserID %>' == 0) {
                $('#divKeterangan').html('<center><b>Bila sudah terdaftar di OJK, mohon melakukan aksi korporasi melalui menu setelah login.</b></center>');
            }

            var id = $('#hfID').val();
            if (id > 0) {

                $('#btnNext').hide();
                $('#btnSubmit').show();

                $('#trNilai').show();

                var typeId = $('#ddlCorporateActionType').val();

                if (typeId == '1') {
                    $('#lblNilai').text('Total Aset');
                }
                else if (typeId == '4') {
                    $('#lblNilai').text('Nilai Emisi');
                }
                else if (typeId == '') {
                    $('#lblNilai').text('');
                }
                else {
                    $('#lblNilai').text('Per Tindakan');
                }

            }

        });

    </script>
    <script type="text/javascript">

        $(document).ready(function () {

            $('#ddlWilayah').change(function () {

                $citys = $('#ddlKota');
                $citys.get(0).options.length = 0;

                var regionId = $("#ddlWilayah option:selected").val();

                if (regionId > 0) {

                    var handlerUrl = '<%= ResolveUrl("~/AjaxHandler/Loaddata/getcity.ashx?region_id=") %>';

                    $.ajax({
                        type: 'POST',
                        url: handlerUrl + regionId,
                        contentType: 'application/json',
                        dataType: 'json',
                        success: function (datas) {

                            if (datas.length > 1) {
                                $citys.get(0).options[0] = new Option("-- pilih kota --", "");
                                $.each(datas, function (i, data) {
                                    $citys.append('<option value="' + data.CityID + '">' + data.CityCode + " - " + data.CityName + '</option>');
                                });

                            } else if (datas.length == 1) {
                                $citys.append('<option value="' + datas[0].CityID + '">' + datas[0].CityCode + " - " + datas[0].CityName + '</option>');
                            }

                            $citys.trigger('chosen:updated');

                        },
                        error: function () {
                            alert('Error!');
                        }
                    });
                }
                else {
                    $citys.get(0).options.length = 0;
                    $citys.get(0).options[0] = new Option("-- pilih kota --", "");
                    $citys.trigger('chosen:updated');
                }


            });

            $('#ddlDebtor').change(function () {

                var debtorId = $("#ddlDebtor option:selected").val();
                $sectors = $('#ddlSubSubSector');
                $sectors.get(0).options.length = 0;

                if (debtorId > 0) {

                    var handlerUrl = '<%= ResolveUrl("~/AjaxHandler/LoadData/getDebtorSector.ashx?debtor_id=") %>';

                    $.ajax({
                        type: 'POST',
                        url: handlerUrl + debtorId + '&method=getdatabydebtorcorporateaction',
                        contentType: 'application/json',
                        dataType: 'json',
                        success: function (datas) {

                            if (datas.length > 1) {
                                $sectors.get(0).options[0] = new Option("-- pilih jenis usaha emiten --", "");
                                $.each(datas, function (i, data) {

                                    // Format Value -> SectorCode | SubSectorCode | SubSubSectorID | DebtorSectorID
                                    $sectors.append('<option value="' + data.recSector.SectorCode + "|" + data.recSubSector.SubSectorCode + "|" + data.SubSubSectorID + "|" + data.DebtorSectorID + '">' + data.recSector.SectorName + ' - ' + data.recSubSector.SubSectorName + ' - ' + data.recSubSubSector.SubSubSectorName + '</option>');

                                });
                            }
                            else if (datas.length == 1) {

                                // Format Value -> SectorCode | SubSectorCode | SubSubSectorID | DebtorSectorID
                                $sectors.append('<option value="' + datas[0].recSector.SectorCode + "|" + datas[0].recSubSector.SubSectorCode + "|" + datas[0].SubSubSectorID + "|" + datas[0].DebtorSectorID + '">' + datas[0].recSector.SectorName + ' - ' + datas[0].recSubSector.SubSectorName + ' - ' + datas[0].recSubSubSector.SubSubSectorName + '</option>');

                                GetTariff();
                            }

                            $sectors.trigger("chosen:updated");

                        },
                        error: function () {
                            alert('Error!');
                        }
                    });
                }
                else {
                    $sectors.get(0).options.length = 0;
                    $sectors.get(0).options[0] = new Option("-- pilih jenis usaha emiten --", "");
                    $sectors.trigger("chosen:updated");
                }

            });

            $('#ddlCorporateActionType').change(function () {

                $('#trNilai').show();

                var typeId = $(this).val();

                if (typeId == '1') {
                    $('#lblNilai').text('Total Aset');
                }
                else if (typeId == '4') {
                    $('#lblNilai').text('Nilai Emisi');
                }
                else if (typeId == '') {
                    $('#lblNilai').text('');
                }
                else {
                    $('#lblNilai').text('Per Tindakan');
                }

                if (typeId > 0) {

                    var handlerUrl = '<%= ResolveUrl("~/AjaxHandler/LoadData/getDebtor.ashx") %>';

                    $debtors = $('#ddlDebtor');
                    $debtors.get(0).options.length = 0;

                    $.ajax({
                        type: 'POST',
                        url: handlerUrl + '?method=getbycorporateactiontype&CorporateActionTypeID=' + typeId,
                        contentType: 'application/json',
                        dataType: 'json',
                        success: function (datas) {

                            if (datas.length > 1) {
                                $debtors.get(0).options[0] = new Option("-- pilih emiten aksi --", "");
                                $.each(datas, function (i, data) {

                                    $debtors.append('<option value="' + data.DebtorID + '">' + data.DebtorName + '</option>');

                                });

                            }
                            else if (datas.length == 1) {

                                $debtors.append('<option value="' + datas[0].DebtorID + '">' + datas[0].DebtorName + '</option>');

                            }

                            $debtors.trigger('chosen:updated');

                            $('#ddlDebtor').change();

                        },
                        error: function () {
                            alert('Error!');
                        }
                    });
                }
            });

            $('#ddlSubSubSector').change(function () {
                GetTariff();
            });

        });

    </script>
</head>
<body onload="StartTimers();" onmousemove="ResetTimers();" onkeydown="ResetTimers();">
    <form id="form1" runat="server">
    <div id="divKeterangan">
    </div>
    <br />
    <fieldset id="fsProfilPerusahaan">
        <legend><b>Profil Perusahaan</b></legend>
        <div>
            <table border="0">
                <tr id="trCorporateName" runat="server">
                    <td class="spasiRow">
                        Nama Perusahaan
                    </td>
                    <td width="10">
                        :
                    </td>
                    <td>
                        <asp:TextBox ID="txtCorporateName" runat="server" Width="500"></asp:TextBox>
                        <span style="color: Red;">*</span>
                    </td>
                </tr>
                <tr id="trCorporateSector" runat="server">
                    <td class="spasiRow">
                        Jenis Usaha
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:TextBox ID="txtCorporateSector" runat="server" MaxLength="50" Width="200"></asp:TextBox>
                    </td>
                </tr>
                <tr id="trNPWP" runat="server">
                    <td class="spasi2Row">
                        NPWP
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:TextBox ID="txtNPWP" runat="server" Width="200"></asp:TextBox>&nbsp;<span style="color: Red;">*</span>
                        <br />
                        Jika tidak mempunyai NPWP untuk perseorangan, harap hubungi CS OJK
                    </td>
                </tr>
                <tr id="trAddress1" runat="server">
                    <td class="spasiRow">
                        Alamat&nbsp;
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:TextBox ID="txtAlamat1" runat="server" Width="350"></asp:TextBox>
                    </td>
                </tr>
                <tr id="trAddress2" runat="server">
                    <td class="spasiRow">
                        &nbsp;</td>
                    <td>
                        &nbsp;</td>
                    <td>
                        <asp:TextBox ID="txtAlamat2" runat="server" Width="350"></asp:TextBox>
                    </td>
                </tr>
                <tr id="trAddress3" runat="server">
                    <td class="spasiRow">
                        &nbsp;</td>
                    <td>
                        &nbsp;</td>
                    <td>
                        <asp:TextBox ID="txtAlamat3" runat="server" Width="350"></asp:TextBox>
                    </td>
                </tr>
                <tr id="trRegion" runat="server">
                    <td class="spasiRow">
                        Wilayah
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:DropDownList ID="ddlWilayah" runat="server" Width="200">
                        </asp:DropDownList>
                    </td>
                </tr>
                <tr id="trCity" runat="server">
                    <td class="spasiRow">
                        Kota
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:DropDownList ID="ddlKota" runat="server" Width="200">
                        </asp:DropDownList>
                    </td>
                </tr>
                <tr id="trZipCode" runat="server">
                    <td class="spasiRow">
                        Kode Pos
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:TextBox ID="txtKodePos" runat="server" MaxLength="5" Width="200"></asp:TextBox>
                    </td>
                </tr>
                <tr id="trPhone" runat="server">
                    <td class="spasiRow">
                        Telepon
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:TextBox ID="txtTelpon" runat="server" Width="200"></asp:TextBox>
                        Fax :
                        <asp:TextBox ID="txtFax" runat="server" Width="200"></asp:TextBox>
                    </td>
                </tr>
                <tr id="trEmail" runat="server">
                    <td class="spasiRow">
                        Email
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:TextBox ID="txtEmail" runat="server" Width="200"></asp:TextBox>&nbsp;<span style="color: Red;">*</span>
                    </td>
                </tr>
                <tr id="trWebSite" runat="server">
                    <td class="spasiRow">
                        Website
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:TextBox ID="txtWebsite" runat="server" Width="200"></asp:TextBox>
                    </td>
                </tr>
                <tr id="trCorporateActionType">
                    <td class="spasiRow">
                        Jenis Aksi Korporasi
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:DropDownList ID="ddlCorporateActionType" runat="server" Width="335">
                        </asp:DropDownList>
                        &nbsp;<span style="color: Red;">*</span>
                    </td>
                </tr>
                <tr id="trDebtor">
                    <td class="spasiRow">
                        Emiten Aksi
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:DropDownList ID="ddlDebtor" runat="server" Width="300">
                        </asp:DropDownList>
                        &nbsp;<span style="color: Red;">*</span>
                    </td>
                </tr>
                <tr id="trSubSubSector">
                    <td class="spasiRow">
                        Jenis Usaha Emiten
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:DropDownList ID="ddlSubSubSector" runat="server" Width="300">
                        </asp:DropDownList>
                        &nbsp;<span style="color: Red;">*</span>
                        <br />
                    </td>
                </tr>
                <tr id="trNilai">
                    <td class="spasiRow">
                        <label id="lblNilai">
                        </label>
                    </td>
                    <td>
                        :
                    </td>
                    <td>
                        <asp:TextBox ID="txtNilaiEmisi" runat="server" Width="200"></asp:TextBox>
                    </td>
                </tr>
            </table>
        </div>
    </fieldset>
    <fieldset id="fsKonfirmasi" runat="server">
        <legend>Konfirmasi</legend>
        <div>
            <table border="0" cellpadding="2" cellspacing="2">
                <tr>
                    <td style="width: 50">
                    </td>
                    <td>
                    </td>
                    <td colspan="3">
                    </td>
                </tr>
                <tr>
                    <td style="width: 50">
                    </td>
                    <td>
                    </td>
                    <td colspan="3">
                        <asp:Label ID="lblValidasi" runat="server" ForeColor="#000099"></asp:Label>
                    </td>
                </tr>
            </table>
        </div>
    </fieldset>
    <div class="captchaLogin" id="tableCaptcha">
        <div class="headCaptcha">
            CAPTCHA</div>
        <div class="imageCaptcha">
            <div style="text-align: center">
                <input type="text" id="txtCaptcha1" name="txtCaptcha1" style="width: 54px !important;" />
            </div>
        </div>
    </div>
    <br />
    <table border="0">
        <tr>
            <td colspan="2">
                &nbsp;
            </td>
            <td>
                <div style="text-align: right; padding-top: 10px;">
                    <button id="btnCancel" type="button">
                        Batal</button>
                    <button id="btnBack" type="button" runat="server">
                        Kembali</button>
                    <button id="btnNext" type="button">
                        Lanjut</button>
                    <button id="btnSubmit" type="submit" runat="server">
                        Submit</button>
                </div>
            </td>
        </tr>
        <tr>
            <td colspan="3">
                <asp:HiddenField ID="hfInvoiceValue" runat="server" />
                <asp:HiddenField ID="hfID" runat="server" />
                <asp:HiddenField ID="hfInvoiceNo" runat="server" />
                <asp:HiddenField ID="hfInvoiceDate" runat="server" />
                <asp:HiddenField ID="hfBillingNo" runat="server" />
                <asp:HiddenField ID="hfCorporateActionDate" runat="server" />
                <asp:HiddenField ID="hfImpositionBaseID" runat="server" />
                <asp:HiddenField ID="hfDebtorSectorID" runat="server" />
                <input type="hidden" id="txtExpire" name="txtExpire" value='0' />
                <input type="hidden" id="hdBeSpelled" name="hdBeSpelled" />
                <input type="hidden" id="txtTariffId" name="txtTariffId" />
            </td>
        </tr>
    </table>
    </form>
</body>
</html>
